package study;

import static java.lang.System.out;

import java.io.Serializable;
import java.rmi.Remote;
import java.rmi.RemoteException;

public class SayHelloServer implements Cat, Dog, Serializable {

	protected SayHelloServer() throws RemoteException {

	}

	@Override
	public void dogSayHello() throws RemoteException {
		out.println("Hello, I am a Dogrrr.");

	}

	@Override
	public void catSayHello() throws RemoteException {
		out.println("Hello, I am a Catrrr.");

	}

}

interface Cat extends Remote {
	public void catSayHello() throws RemoteException;
}

interface Dog extends Remote {
	public void dogSayHello() throws RemoteException;
}
